The Python Object Protocol

A "good" object protocol, allows one to control meta, hence being able to modify the behaviour and the notation of the language itself. Python achieves this through dunder methods. Allowing python to be a multi-paradign language

Make use of dunder methods for better readability, and extensibility


Special cases aren't special enough to break the rules.
Although practicality beats purity.

Providing an implementation of dunder len and getitem allows the class to be more explicit, in the sense it holds some data.

It is also worth mentioning a builtin's len method != dunder len, since directly reads the ob_size field in python bytecode

Infix methods, such as ones those enable LHS and RHS representations, such as dunder le, gt etc should also be provided if is appropriate to do so

Muggle Methods: a feature not generally publicized, but makes

Containers

Dictionaries

Data Classes